//
//  YXYBaseViewController.m
//  Topit
//
//  Created by dllo on 15/12/16.
//  Copyright © 2015年 YXY. All rights reserved.
//

#import "YXYBaseViewController.h"

@interface YXYBaseViewController ()

@end

@implementation YXYBaseViewController

- (void)viewDidLoad {
    [super viewDidLoad];
    self.navigationController.navigationBar.barTintColor = [UIColor whiteColor];
    // Do any additional setup after loading the view.
}

- (void)viewWillAppear:(BOOL)animated {
    NSUserDefaults *user = [NSUserDefaults standardUserDefaults];
    NSString *passWord = [user objectForKey:@"NightMode"];
    if ([passWord isEqualToString:@"Night"]) {
        self.navigationController.navigationBar.barTintColor = [UIColor grayColor];
    }else {
        self.navigationController.navigationBar.barTintColor = [UIColor whiteColor];
    }
}
- (void)didReceiveMemoryWarning {
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}

/*
#pragma mark - Navigation

// In a storyboard-based application, you will often want to do a little preparation before navigation
- (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender {
    // Get the new view controller using [segue destinationViewController].
    // Pass the selected object to the new view controller.
}
*/

@end
